import request from '@/utils/request'

// api地址
const api = {
  liveList:'api/live/list',
  liveJoin: 'api/live/join',
  liveSend: 'api/live/send',
  liveLeave: 'api/live/leave',
  liveOpen: 'api/live/open'
}

// 直播列表
export const liveList = (data) => {
  return request.post(api.liveList, data)
}

// 加入直播间
export const liveJoin = (data) => {
  return request.post(api.liveJoin, data)
}

// 发送消息
export const liveSend = (data) => {
  return request.post(api.liveSend, data)
}

// 离开直播间
export const liveLeave = (data) => {
  return request.post(api.liveLeave, data)
}

// 公开课
export const liveOpen = (data) => {
  return request.post(api.liveOpen, data)
}
